var tecMainPage = {};

tecMainPage.init = function () {




  var ALLTERRAIN_LINE = $('.ALLTERRAIN_LINE')
    , FusionKnit_Line = $('.FusionKnit_Line')
    , HEAT_NAVI_Line = $('.HEAT_NAVI_Line')
    , F_360_Line = $('.F_360_Line')
    , PT_ZERO_Line = $('.PT_ZERO_Line')
    , Motion_Knit_Line = $('.Motion_Knit_Line')
    , SIO_Line = $('.SIO_Line')
    , Motion_3D_Line = $('.Motion_3D_Line');


  var tl_ALLTERRAIN_LINE = new TimelineMax({delay: .3})
    , tl_FusionKnit_Line = new TimelineMax({delay: 1})
    , tl_HEAT_NAVI_Line = new TimelineMax({delay: .6})
    , tl_F_360_Line = new TimelineMax({delay: 2})
    , tl_PT_ZERO_Line = new TimelineMax({delay: 1.2})
    , tl_Motion_Knit_Line = new TimelineMax({delay: 4})
    , tl_SIO_Line = new TimelineMax({delay: 2.4})
    , tl_Motion_3D_Line = new TimelineMax({delay: 6});

  tecMainPage.tl_ALLTERRAIN_LINE = tl_ALLTERRAIN_LINE;
  tecMainPage.tl_FusionKnit_Line = tl_FusionKnit_Line;
  tecMainPage.tl_HEAT_NAVI_Line = tl_HEAT_NAVI_Line;
  tecMainPage.tl_F_360_Line = tl_F_360_Line;
  tecMainPage.tl_PT_ZERO_Line = tl_PT_ZERO_Line;
  tecMainPage.tl_Motion_Knit_Line = tl_Motion_Knit_Line;
  tecMainPage.tl_SIO_Line = tl_SIO_Line;
  tecMainPage.tl_Motion_3D_Line = tl_Motion_3D_Line;


  tl_ALLTERRAIN_LINE.fromTo(ALLTERRAIN_LINE, .8, {scale: 0}, {scale: 1});
  tl_ALLTERRAIN_LINE.to(ALLTERRAIN_LINE, 1, {transformOrigin: 'center', scale: 0, delay: .4});
  tl_ALLTERRAIN_LINE.to(ALLTERRAIN_LINE, .542, {scale: 1});


  tl_FusionKnit_Line.fromTo(FusionKnit_Line, .8, {scale: 0, transformOrigin: 'right'}, {scale: 1});
  tl_FusionKnit_Line.to(FusionKnit_Line, 1, {transformOrigin: 'center', scale: 0, delay: .5});
  tl_FusionKnit_Line.to(FusionKnit_Line, .504, {scale: 1});


  tl_HEAT_NAVI_Line.fromTo(HEAT_NAVI_Line, .8, {scale: 0, transformOrigin: 'left'}, {scale: 1});
  tl_HEAT_NAVI_Line.to(HEAT_NAVI_Line, 1, {scale: 0, transformOrigin: 'center', delay: .2});
  tl_HEAT_NAVI_Line.to(HEAT_NAVI_Line, .622, {scale: 1});


  tl_F_360_Line.fromTo(F_360_Line, .8, {scale: 0, transformOrigin: 'right'}, {scale: 1});
  tl_F_360_Line.to(F_360_Line, 1, {scale: 0, transformOrigin: 'center', delay: .1});
  tl_F_360_Line.to(F_360_Line, .591, {scale: 1});


  tl_PT_ZERO_Line.fromTo(PT_ZERO_Line, .8, {scale: 0, transformOrigin: 'left'}, {scale: 1});
  tl_PT_ZERO_Line.to(PT_ZERO_Line, 1, {scale: 0, transformOrigin: 'center', delay: .3});
  tl_PT_ZERO_Line.to(PT_ZERO_Line, .448, {scale: 1});


  tl_Motion_Knit_Line.fromTo(Motion_Knit_Line, .8, {scale: 0, transformOrigin: 'right'}, {scale: 1});
  tl_Motion_Knit_Line.to(Motion_Knit_Line, 1, {scale: 0, transformOrigin: 'center', delay: .2});
  tl_Motion_Knit_Line.to(Motion_Knit_Line, .591, {scale: 1});


  tl_SIO_Line.fromTo(SIO_Line, .8, {scale: 0, transformOrigin: 'left'}, {scale: 1, delay: 2});
  tl_SIO_Line.to(SIO_Line, 1, {scale: 0, transformOrigin: 'center', delay: .3});
  tl_SIO_Line.to(SIO_Line, .629, {scale: 1});


  tl_Motion_3D_Line.fromTo(Motion_3D_Line, .8, {scale: 0, transformOrigin: 'right'}, {scale: 1});
  tl_Motion_3D_Line.to(Motion_3D_Line, 1, {scale: 0, transformOrigin: 'center', delay: .4});
  tl_Motion_3D_Line.to(Motion_3D_Line, .719, {scale: 1});


  TweenMax.set('.TEC_list', {x: '100%'});


  if (tecMainPage.isInit) {
    return
  }



  tecMainPage.isInit = true;
};


tecMainPage.hide = function () {
  $('#HOME_PAGE').fadeIn();
  $('#INNOVATIVE_TECH').fadeOut();
  tecMainPage.tl_ALLTERRAIN_LINE.kill();
  tecMainPage.tl_FusionKnit_Line.kill();
  tecMainPage.tl_HEAT_NAVI_Line.kill();
  tecMainPage.tl_F_360_Line.kill();
  tecMainPage.tl_PT_ZERO_Line.kill();
  tecMainPage.tl_Motion_Knit_Line.kill();
  tecMainPage.tl_SIO_Line.kill();
  tecMainPage.tl_Motion_3D_Line.kill();
};


tecMainPage.TEC_Allterrain = function () {
  TweenMax.to('.TEC_Allterrain', .4, {x: '0%'})
};

$(function () {
  new BScroll('.TEC_Allterrain', {
    scrollbar: {
      fade: true,
      interactive: false // 1.8.0 新增
    }
  });

  $('.ALLTERRAIN').click(function () {

    tecMainPage.TEC_Allterrain()
  });
});
